<?

	function reg_mail($mail, $uname, $password, $category)
	{
		$code 	 = crypt($mail."rajkot", "rajkotrajkot");
		$to      = $mail;
		$base    = $_SERVER['HTTP_HOST'];
		$subject = "confirmation of your registration on rajkot !!!";
		$message = "click on the confirmatino link to acitvate you account on rajkot !!!" . "<br>"  .
			"<a href = '$base/confirmation.php?user=$uname&code=$code&category=$category'>"."confirmation link"."</a>" . "<br>"  .
			"Your Details are as follows :<br>" .
			"Username : ". $uname . "<br>" .
			"Email : ". $mail . "<br>" .
			"Password : ". $password . "<br>" .
			"Category : ". $category . "<br>" .
			"enjoy !!!";
		$headers = "From: rajkot@rajkot.com" . "\r\n" .
			"Reply-To: no-reply@rajkot.com" . "\r\n" .
			"Content-Type: text/html;" . "\r\n" .
			"X-Mailer: PHP/" . phpversion();
		if(mail($to, $subject, $message, $headers))
		{
			return true;
		}
		else
		{
			return false;
		}
	}

?>
